﻿//********************************************************************************//
//创建日期：<创建日期，2010-08-02>
//创建作者：<王一飞，wangyifei@shanghai3h.com>
//功能说明：QS_QT_FAPIAOFHJK实体层次
//********************************************************************************//

#region Entity

using System;
using System.Data;
using Entity;
using Oracle.DataAccess.Client;
using Platform.Configuration;
using Platform.Data;

namespace Entity
{
    [Serializable]
    public class QS_QT_FAPIAOFHJK
    {
        private decimal m_dec_i_jlzt;

        private decimal m_dec_i_m;

        private decimal m_dec_i_type;

        private decimal m_dec_i_y;

        private decimal m_dec_id;

        private DateTime? m_DT_d_tianjiarq;

        private DateTime? m_DT_d_xiugairq;

        private string m_str_s_beizhu;

        private string m_str_s_fapiaoh;

        private string m_str_s_feiyongbh;

        private string m_str_s_feiyongguid;

        private string m_str_s_peisongrq;

        private string m_str_s_tianjiar;

        private string m_str_s_wenjianmc;

        private string m_str_s_xiugair;

        private string m_str_s_yonghuh;

        private string m_str_s_yonghum;

        private string m_str_s_youjianhm;

        /// <summary>
        ///     主键
        /// </summary>
        public decimal ID
        {
            get { return m_dec_id; }
            set { m_dec_id = value; }
        }

        /// <summary>
        ///     文件名称
        /// </summary>
        public string S_WENJIANMC
        {
            get { return m_str_s_wenjianmc; }
            set { m_str_s_wenjianmc = value; }
        }

        /// <summary>
        ///     水量年
        /// </summary>
        public decimal I_Y
        {
            get { return m_dec_i_y; }
            set { m_dec_i_y = value; }
        }

        /// <summary>
        ///     水量月
        /// </summary>
        public decimal I_M
        {
            get { return m_dec_i_m; }
            set { m_dec_i_m = value; }
        }

        /// <summary>
        /// </summary>
        public string S_FEIYONGGUID
        {
            get { return m_str_s_feiyongguid; }
            set { m_str_s_feiyongguid = value; }
        }

        /// <summary>
        ///     费用编号
        /// </summary>
        public string S_FEIYONGBH
        {
            get { return m_str_s_feiyongbh; }
            set { m_str_s_feiyongbh = value; }
        }

        /// <summary>
        ///     用户号
        /// </summary>
        public string S_YONGHUH
        {
            get { return m_str_s_yonghuh; }
            set { m_str_s_yonghuh = value; }
        }

        /// <summary>
        ///     用户名
        /// </summary>
        public string S_YONGHUM
        {
            get { return m_str_s_yonghum; }
            set { m_str_s_yonghum = value; }
        }

        /// <summary>
        ///     发票号
        /// </summary>
        public string S_FAPIAOH
        {
            get { return m_str_s_fapiaoh; }
            set { m_str_s_fapiaoh = value; }
        }

        /// <summary>
        ///     邮件号码
        /// </summary>
        public string S_YOUJIANHM
        {
            get { return m_str_s_youjianhm; }
            set { m_str_s_youjianhm = value; }
        }

        /// <summary>
        ///     配送日期
        /// </summary>
        public string S_PEISONGRQ
        {
            get { return m_str_s_peisongrq; }
            set { m_str_s_peisongrq = value; }
        }

        /// <summary>
        /// </summary>
        public decimal I_TYPE
        {
            get { return m_dec_i_type; }
            set { m_dec_i_type = value; }
        }

        /// <summary>
        ///     备注
        /// </summary>
        public string S_BEIZHU
        {
            get { return m_str_s_beizhu; }
            set { m_str_s_beizhu = value; }
        }

        /// <summary>
        ///     记录状态
        /// </summary>
        public decimal I_JLZT
        {
            get { return m_dec_i_jlzt; }
            set { m_dec_i_jlzt = value; }
        }

        /// <summary>
        ///     添加人
        /// </summary>
        public string S_TIANJIAR
        {
            get { return m_str_s_tianjiar; }
            set { m_str_s_tianjiar = value; }
        }

        /// <summary>
        ///     添加日期
        /// </summary>
        public DateTime? D_TIANJIARQ
        {
            get { return m_DT_d_tianjiarq; }
            set { m_DT_d_tianjiarq = value; }
        }

        /// <summary>
        ///     修改人
        /// </summary>
        public string S_XIUGAIR
        {
            get { return m_str_s_xiugair; }
            set { m_str_s_xiugair = value; }
        }

        /// <summary>
        ///     修改日期
        /// </summary>
        public DateTime? D_XIUGAIRQ
        {
            get { return m_DT_d_xiugairq; }
            set { m_DT_d_xiugairq = value; }
        }
    }
}

#endregion

#region EntityProcess

namespace BLL.Access
{
    //using System.Data.OracleClient;

    public class QS_QT_FAPIAOFHJKProcess
    {
        #region Field

        protected string conn;

        #endregion

        #region Construction

        public QS_QT_FAPIAOFHJKProcess()
        {
            conn = ConfigHelper.PlatformConnString;
        }

        #endregion

        #region public

        /// <summary>
        ///     根据QS_QT_FAPIAOFHJK实体添加或者修改QS_QT_FAPIAOFHJK信息
        /// </summary>
        public bool InsertOrUpdate(QS_QT_FAPIAOFHJK QS_QT_FAPIAOFHJK, OracleTransaction Transaction)
        {
            if (QS_QT_FAPIAOFHJK.ID == 0)
                InsertQS_QT_FAPIAOFHJK(QS_QT_FAPIAOFHJK, Transaction);
            else
                UpdateQS_QT_FAPIAOFHJK(QS_QT_FAPIAOFHJK, Transaction);
            return QS_QT_FAPIAOFHJK.ID == 0 ? false : true;
        }

        /// <summary>
        ///     根据QS_QT_FAPIAOFHJK实体添加或修改QS_QT_FAPIAOFHJK信息
        /// </summary>
        public bool InsertOrUpdate(QS_QT_FAPIAOFHJK QS_QT_FAPIAOFHJK)
        {
            return InsertOrUpdate(QS_QT_FAPIAOFHJK, null);
        }


        /// <summary>
        ///     根据QS_QT_FAPIAOFHJK主键删除QS_QT_FAPIAOFHJK信息
        /// </summary>
        /// <param name="ID"></param>
        public bool DeleteQS_QT_FAPIAOFHJK(decimal ID, OracleTransaction Transaction)
        {
            var spName = "CS_DelQS_QT_FAPIAOFHJK";
            var storedParams = OracleHelperParameterCache.GetSpParameterSet(conn, spName);
            storedParams[0].Value = ID;
            var result = 0;
            if (Transaction == null)
                result = OracleHelper.ExecuteNonQuery(conn, CommandType.StoredProcedure, spName, storedParams);
            else
                result = OracleHelper.ExecuteNonQuery(Transaction, CommandType.StoredProcedure, spName, storedParams);
            return result == 0 ? false : true;
        }

        /// <summary>
        ///     根据QS_QT_FAPIAOFHJK主键删除QS_QT_FAPIAOFHJK信息
        /// </summary>
        /// <param name="ID"></param>
        public bool DeleteQS_QT_FAPIAOFHJK(decimal ID)
        {
            return DeleteQS_QT_FAPIAOFHJK(ID, null);
        }

        /// <summary>
        ///     根据条件删除QS_QT_FAPIAOFHJK信息
        /// </summary>
        /// <param name="WhereClause">条件子句(Oracle语句)不带where</param>
        /// <param name="Transaction">事务，如果为null,则不做事务</param>
        /// <returns>如果删除成功，返回true,否则返回fals</returns>
        public bool DeleteQS_QT_FAPIAOFHJKsDynamic(string WhereClause, OracleTransaction Transaction)
        {
            var spName = "CS_DelQS_QT_FAPIAOFHJKsDyn";
            var storedParams = OracleHelperParameterCache.GetSpParameterSet(conn, spName);
            storedParams[0].Value = WhereClause;
            var result = 0;
            if (Transaction == null)
                result = OracleHelper.ExecuteNonQuery(conn, CommandType.StoredProcedure, spName, storedParams);
            else
                result = OracleHelper.ExecuteNonQuery(Transaction, CommandType.StoredProcedure, spName, storedParams);
            return result == 0 ? false : true;
        }

        /// <summary>
        ///     根据条件删除QS_QT_FAPIAOFHJK信息
        /// </summary>
        /// <param name="WhereClause">条件子句(Oracle语句)不带where</param>
        /// <param name="Transaction">事务，如果为null,则不做事务</param>
        /// <returns>如果删除成功，返回true,否则返回fals</returns>
        public bool DeleteQS_QT_FAPIAOFHJKsDynamic(string WhereClause)
        {
            return DeleteQS_QT_FAPIAOFHJKsDynamic(WhereClause, null);
        }

        /// <summary>
        ///     根据QS_QT_FAPIAOFHJK主键选择QS_QT_FAPIAOFHJK信息
        /// </summary>
        /// <param name="Transaction">事务，如果为null,则不做事务</param>
        /// <returns>QS_QT_FAPIAOFHJK信息</returns>
        public QS_QT_FAPIAOFHJK SelectQS_QT_FAPIAOFHJK(decimal ID, OracleTransaction Transaction)
        {
            var spName = "CS_SelQS_QT_FAPIAOFHJK";
            var storedParams = OracleHelperParameterCache.GetSpParameterSet(conn, spName);
            storedParams[0].Value = ID;
            OracleDataReader rd;
            if (Transaction == null)
                rd = OracleHelper.ExecuteReader(conn, CommandType.StoredProcedure, spName, storedParams);
            else
                rd = OracleHelper.ExecuteReader(Transaction, CommandType.StoredProcedure, spName, storedParams);
            if (rd.Read())
            {
                var QS_QT_FAPIAOFHJK = PopulateQS_QT_FAPIAOFHJK(rd);
                rd.Close();
                return QS_QT_FAPIAOFHJK;
            }
            return null;
        }

        /// <summary>
        ///     根据QS_QT_FAPIAOFHJK主键选择QS_QT_FAPIAOFHJK信息
        /// </summary>
        /// <returns>QS_QT_FAPIAOFHJK信息</returns>
        public QS_QT_FAPIAOFHJK SelectQS_QT_FAPIAOFHJK(decimal ID)
        {
            return SelectQS_QT_FAPIAOFHJK(ID, null);
        }

        /// <summary>
        ///     选择所有QS_QT_FAPIAOFHJK信息
        /// </summary>
        /// <param name="Transaction">事务，如果为null,则不做事务</param>
        /// <returns>所有QS_QT_FAPIAOFHJK信息</returns>
        public DataTable SelectQS_QT_FAPIAOFHJKsAll(OracleTransaction Transaction)
        {
            var spName = "CS_SelQS_QT_FAPIAOFHJKsAll";
            var storedParams = OracleHelperParameterCache.GetSpParameterSet(conn, spName);
            DataSet ds = null;
            if (Transaction == null)
                ds = OracleHelper.ExecuteDataset(conn, CommandType.StoredProcedure, spName, storedParams);
            else
                ds = OracleHelper.ExecuteDataset(Transaction, CommandType.StoredProcedure, spName, storedParams);
            if (ds != null && ds.Tables.Count > 0)
            {
                AddRowNumber(ds.Tables[0]);
                return ds.Tables[0];
            }
            return null;
        }

        /// <summary>
        ///     选择所有QS_QT_FAPIAOFHJK信息
        /// </summary>
        /// <returns>所有QS_QT_FAPIAOFHJK信息</returns>
        public DataTable SelectQS_QT_FAPIAOFHJKsAll()
        {
            return SelectQS_QT_FAPIAOFHJKsAll(null);
        }

        /// <summary>
        ///     根据条件选择QS_QT_FAPIAOFHJK信息
        /// </summary>
        /// <param name="WhereClause">条件子句(不带where)</param>
        /// <param name="OrderByExpression">排序子句</param>
        /// <param name="Transaction">事务，如果为null,则不做事务</param>
        /// <returns>QS_QT_FAPIAOFHJK信息</returns>
        public DataTable SelectQS_QT_FAPIAOFHJKsDynamic(string WhereClause, string OrderByExpression,
            OracleTransaction Transaction)
        {
            var spName = "CS_SelQS_QT_FAPIAOFHJKsDyn";
            var storedParams = OracleHelperParameterCache.GetSpParameterSet(conn, spName);
            storedParams[0].Value = string.IsNullOrEmpty(WhereClause.Trim()) ? "1=1" : WhereClause;
            storedParams[1].Value = OrderByExpression;
            DataSet ds = null;
            if (Transaction == null)
                ds = OracleHelper.ExecuteDataset(conn, CommandType.StoredProcedure, spName, storedParams);
            else
                ds = OracleHelper.ExecuteDataset(Transaction, CommandType.StoredProcedure, spName, storedParams);
            if (ds != null && ds.Tables.Count > 0)
            {
                AddRowNumber(ds.Tables[0]);
                return ds.Tables[0];
            }
            return null;
        }


        /// <summary>
        ///     根据条件选择QS_QT_FAPIAOFHJK信息
        /// </summary>
        /// <param name="WhereClause">条件子句(不带where)</param>
        /// <param name="OrderByExpression">排序子句</param>
        /// <returns>QS_QT_FAPIAOFHJK信息</returns>
        public DataTable SelectQS_QT_FAPIAOFHJKsDynamic(string WhereClause, string OrderByExpression)
        {
            return SelectQS_QT_FAPIAOFHJKsDynamic(WhereClause, OrderByExpression, null);
        }


        /// <summary>
        ///     根据条件选择QS_QT_FAPIAOFHJK信息
        /// </summary>
        /// <param name="WhereClause">条件子句(不带where)</param>
        /// <param name="OrderByExpression">排序子句</param>
        /// <param name="PageIndex">页码</param>
        /// <param name="PageSize">页数</param>
        /// <param name="Transaction">事务，如果为null,则不做事务</param>
        /// <returns>QS_QT_FAPIAOFHJK信息</returns>
        public DataTable SelectQS_QT_FAPIAOFHJKsDynamic(string WhereClause, string OrderByExpression, int PageIndex,
            int PageSize, OracleTransaction Transaction)
        {
            var spName = "CS_SelQS_QT_FAPIAOFHJKsDynPaged";
            var storedParams = OracleHelperParameterCache.GetSpParameterSet(conn, spName);
            storedParams[0].Value = string.IsNullOrEmpty(WhereClause.Trim()) ? "1=1" : WhereClause;
            storedParams[1].Value = OrderByExpression;
            storedParams[2].Value = PageIndex;
            storedParams[3].Value = PageSize;
            DataSet ds = null;
            if (Transaction == null)
                ds = OracleHelper.ExecuteDataset(conn, CommandType.StoredProcedure, spName, storedParams);
            else
                ds = OracleHelper.ExecuteDataset(Transaction, CommandType.StoredProcedure, spName, storedParams);
            if (ds != null && ds.Tables.Count > 0)
            {
                AddRowNumber(ds.Tables[0]);
                return ds.Tables[0];
            }
            return null;
        }


        /// <summary>
        ///     根据条件选择QS_QT_FAPIAOFHJK信息
        /// </summary>
        /// <param name="WhereClause">条件子句(不带where)</param>
        /// <param name="OrderByExpression">排序子句</param>
        /// <param name="PageIndex">页码</param>
        /// <param name="PageSize">页数</param>
        /// <returns>QS_QT_FAPIAOFHJK信息</returns>
        public DataTable SelectQS_QT_FAPIAOFHJKsDynamic(string WhereClause, string OrderByExpression, int PageIndex,
            int PageSize)
        {
            return SelectQS_QT_FAPIAOFHJKsDynamic(WhereClause, OrderByExpression, PageIndex, PageSize, null);
        }

        /// <summary>
        ///     根据条件更新QS_QT_FAPIAOFHJK字段
        /// </summary>
        /// <returns>受影响行数</returns>
        public int UpdateQS_QT_FAPIAOFHJKsDynamic(string UpdateValue, string WhereClause, OracleTransaction Transaction)
        {
            var result = 0;
            if (UpdateValue == "" || WhereClause == "")
                return 0;
            var spName = "CS_UpdQS_QT_FAPIAOFHJKDyn";
            var storedParams = OracleHelperParameterCache.GetSpParameterSet(conn, spName);
            DataSet ds = null;
            storedParams[0].Value = UpdateValue;
            storedParams[1].Value = WhereClause;
            if (Transaction == null)
                ds = OracleHelper.ExecuteDataset(conn, CommandType.StoredProcedure, spName, storedParams);
            else
                ds = OracleHelper.ExecuteDataset(Transaction, CommandType.StoredProcedure, spName, storedParams);
            result = Convert.ToInt32(storedParams[2].Value);
            return result;
        }

        /// <summary>
        ///     根据条件更新QS_QT_FAPIAOFHJK字段
        /// </summary>
        /// <returns>受影响行数</returns>
        public int UpdateQS_QT_FAPIAOFHJKsDynamic(string UpdateValue, string WhereClause)
        {
            return UpdateQS_QT_FAPIAOFHJKsDynamic(UpdateValue, WhereClause, null);
        }

        #endregion

        #region Private

        private int InsertQS_QT_FAPIAOFHJK(QS_QT_FAPIAOFHJK QS_QT_FAPIAOFHJK, OracleTransaction Transaction)
        {
            var spName = "CS_InsQS_QT_FAPIAOFHJK";
            var storedParams = OracleHelperParameterCache.GetSpParameterSet(conn, spName);
            storedParams[0].Value = QS_QT_FAPIAOFHJK.S_WENJIANMC;
            storedParams[1].Value = QS_QT_FAPIAOFHJK.I_Y;
            storedParams[2].Value = QS_QT_FAPIAOFHJK.I_M;
            storedParams[3].Value = QS_QT_FAPIAOFHJK.S_FEIYONGGUID;
            storedParams[4].Value = QS_QT_FAPIAOFHJK.S_FEIYONGBH;
            storedParams[5].Value = QS_QT_FAPIAOFHJK.S_YONGHUH;
            storedParams[6].Value = QS_QT_FAPIAOFHJK.S_YONGHUM;
            storedParams[7].Value = QS_QT_FAPIAOFHJK.S_FAPIAOH;
            storedParams[8].Value = QS_QT_FAPIAOFHJK.S_YOUJIANHM;
            storedParams[9].Value = QS_QT_FAPIAOFHJK.S_PEISONGRQ;
            storedParams[10].Value = QS_QT_FAPIAOFHJK.I_TYPE;
            storedParams[11].Value = QS_QT_FAPIAOFHJK.S_BEIZHU;
            storedParams[12].Value = QS_QT_FAPIAOFHJK.I_JLZT;
            storedParams[13].Value = QS_QT_FAPIAOFHJK.S_TIANJIAR;
            storedParams[14].Value = QS_QT_FAPIAOFHJK.D_TIANJIARQ;
            storedParams[15].Value = QS_QT_FAPIAOFHJK.S_XIUGAIR;
            storedParams[16].Value = QS_QT_FAPIAOFHJK.D_XIUGAIRQ;
            var result = 0;
            if (Transaction == null)
                result = OracleHelper.ExecuteNonQuery(conn, CommandType.StoredProcedure, spName, storedParams);
            else
                result = OracleHelper.ExecuteNonQuery(Transaction, CommandType.StoredProcedure, spName, storedParams);
            QS_QT_FAPIAOFHJK.ID = Convert.ToInt32(storedParams[17].Value);
            return result;
        }

        private bool UpdateQS_QT_FAPIAOFHJK(QS_QT_FAPIAOFHJK QS_QT_FAPIAOFHJK, OracleTransaction Transaction)
        {
            var spName = "CS_UpdQS_QT_FAPIAOFHJK";
            var storedParams = OracleHelperParameterCache.GetSpParameterSet(conn, spName);
            storedParams[0].Value = QS_QT_FAPIAOFHJK.S_WENJIANMC;
            storedParams[1].Value = QS_QT_FAPIAOFHJK.I_Y;
            storedParams[2].Value = QS_QT_FAPIAOFHJK.I_M;
            storedParams[3].Value = QS_QT_FAPIAOFHJK.S_FEIYONGGUID;
            storedParams[4].Value = QS_QT_FAPIAOFHJK.S_FEIYONGBH;
            storedParams[5].Value = QS_QT_FAPIAOFHJK.S_YONGHUH;
            storedParams[6].Value = QS_QT_FAPIAOFHJK.S_YONGHUM;
            storedParams[7].Value = QS_QT_FAPIAOFHJK.S_FAPIAOH;
            storedParams[8].Value = QS_QT_FAPIAOFHJK.S_YOUJIANHM;
            storedParams[9].Value = QS_QT_FAPIAOFHJK.S_PEISONGRQ;
            storedParams[10].Value = QS_QT_FAPIAOFHJK.I_TYPE;
            storedParams[11].Value = QS_QT_FAPIAOFHJK.S_BEIZHU;
            storedParams[12].Value = QS_QT_FAPIAOFHJK.I_JLZT;
            storedParams[13].Value = QS_QT_FAPIAOFHJK.S_TIANJIAR;
            storedParams[14].Value = QS_QT_FAPIAOFHJK.D_TIANJIARQ;
            storedParams[15].Value = QS_QT_FAPIAOFHJK.S_XIUGAIR;
            storedParams[16].Value = QS_QT_FAPIAOFHJK.D_XIUGAIRQ;
            storedParams[17].Value = QS_QT_FAPIAOFHJK.ID;
            var result = 0;
            if (Transaction == null)
                result = OracleHelper.ExecuteNonQuery(conn, CommandType.StoredProcedure, spName, storedParams);
            else
                result = OracleHelper.ExecuteNonQuery(Transaction, CommandType.StoredProcedure, spName, storedParams);
            return result == 0 ? false : true;
        }


        private QS_QT_FAPIAOFHJK PopulateQS_QT_FAPIAOFHJK(IDataReader dr)
        {
            var QS_QT_FAPIAOFHJK = new QS_QT_FAPIAOFHJK();
            QS_QT_FAPIAOFHJK.ID = dr["ID"] == DBNull.Value ? 0 : (decimal) dr["ID"];
            QS_QT_FAPIAOFHJK.S_WENJIANMC = dr["S_WENJIANMC"] == DBNull.Value ? "" : (string) dr["S_WENJIANMC"];
            QS_QT_FAPIAOFHJK.I_Y = dr["I_Y"] == DBNull.Value ? 0 : (decimal) dr["I_Y"];
            QS_QT_FAPIAOFHJK.I_M = dr["I_M"] == DBNull.Value ? 0 : (decimal) dr["I_M"];
            QS_QT_FAPIAOFHJK.S_FEIYONGGUID = dr["S_FEIYONGGUID"] == DBNull.Value ? "" : (string) dr["S_FEIYONGGUID"];
            QS_QT_FAPIAOFHJK.S_FEIYONGBH = dr["S_FEIYONGBH"] == DBNull.Value ? null : (string) dr["S_FEIYONGBH"];
            QS_QT_FAPIAOFHJK.S_YONGHUH = dr["S_YONGHUH"] == DBNull.Value ? "" : (string) dr["S_YONGHUH"];
            QS_QT_FAPIAOFHJK.S_YONGHUM = dr["S_YONGHUM"] == DBNull.Value ? "" : (string) dr["S_YONGHUM"];
            QS_QT_FAPIAOFHJK.S_FAPIAOH = dr["S_FAPIAOH"] == DBNull.Value ? "" : (string) dr["S_FAPIAOH"];
            QS_QT_FAPIAOFHJK.S_YOUJIANHM = dr["S_YOUJIANHM"] == DBNull.Value ? null : (string) dr["S_YOUJIANHM"];
            QS_QT_FAPIAOFHJK.S_PEISONGRQ = dr["S_PEISONGRQ"] == DBNull.Value ? null : (string) dr["S_PEISONGRQ"];
            QS_QT_FAPIAOFHJK.I_TYPE = dr["I_TYPE"] == DBNull.Value ? 0 : (decimal) dr["I_TYPE"];
            QS_QT_FAPIAOFHJK.S_BEIZHU = dr["S_BEIZHU"] == DBNull.Value ? null : (string) dr["S_BEIZHU"];
            QS_QT_FAPIAOFHJK.I_JLZT = dr["I_JLZT"] == DBNull.Value ? 0 : (decimal) dr["I_JLZT"];
            QS_QT_FAPIAOFHJK.S_TIANJIAR = dr["S_TIANJIAR"] == DBNull.Value ? null : (string) dr["S_TIANJIAR"];
            QS_QT_FAPIAOFHJK.D_TIANJIARQ = dr["D_TIANJIARQ"] == DBNull.Value ? null : (DateTime?) dr["D_TIANJIARQ"];
            QS_QT_FAPIAOFHJK.S_XIUGAIR = dr["S_XIUGAIR"] == DBNull.Value ? null : (string) dr["S_XIUGAIR"];
            QS_QT_FAPIAOFHJK.D_XIUGAIRQ = dr["D_XIUGAIRQ"] == DBNull.Value ? null : (DateTime?) dr["D_XIUGAIRQ"];
            return QS_QT_FAPIAOFHJK;
        }


        private void AddRowNumber(DataTable dt)
        {
            dt.Columns.Add(new DataColumn("RowNumber", typeof(int)));
            for (var i = 0; i < dt.Rows.Count; i++)
                dt.Rows[i][dt.Columns.Count - 1] = i + 1;
        }

        #endregion
    }
}

#endregion